#ifndef CWORKINGDAY_H
#define CWORKINGDAY_H
//------------------------------------------------------------------------------------------------
//  Author: Kebal
//  Date:   6-6-13
//  Desc:   Class to handle day activities, totals and calculations.
//------------------------------------------------------------------------------------------------

//-----------------------
//  Includes
//-----------------------
#include <QDate>
#include <QTime>
#include <QString>


//-----------------------
//  Class
//-----------------------
class   CWorkingDay
{
public:
    //------------------------------------------
    //  Constructors/Destructors and Serializers
    //------------------------------------------
    CWorkingDay();
    CWorkingDay( QString buff );            //  Construct class from data in string buffer

    virtual ~CWorkingDay();                 //  virtual to support inheritance better

    QString     Serialize();                //  Dump data into a buffer ( currently a QString object )


    //------------------------------
    //  Get private member variables
    //------------------------------
    QTime       GetTravelTime();
    QTime       GetDropTime();
    QTime       GetInTime();
    QTime       GetDeliveryTime();

    int         GetTotalDropped();
    int         GetTotalCollected();
    int         GetTotalDelivered();

    int         GetTotalOrdersCollected();
    int         GetTotalOrdersRetailAmount();

    QDate       GetDate();

private:
    QTime       m_tTotalTravel;             //  Total time spent traveling
    QTime       m_tTotalDrop;               //  Total time spent dropping catalogues
    QTime       m_tTotalCollect;            //  Total time spent collecting catalogues
    QTime       m_tTotalDelivery;           //  Total time spent delivering orders

    int         m_iTotalDropped;            //  Total catalogues put out
    int         m_iTotalCollected;          //  Total catalogues collected in
    int         m_iTotalDelivered;          //  Total orders delivered

    int         m_iTotalOrderCollected;     //  Total orders collected
    double      m_fTotalOrderAmount;        //  Total orders collected retail value

    QDate       m_dDate;                    //  The date this day represents

    friend class CToday;
};

#endif // CWORKINGDAY_H
